<template>
    <div id="Hand">
        <v-detail :detailData="inputData" :inputConfig="inputConfig" :rules="rules" ref="input"></v-detail>
    </div>
</template>

<script>
    import detail from "commons/Detail";
    import baseMixin from "@/mixins/BaseMixin";

    export default {
        name: "Hand",
        mixins: [baseMixin],
        props: {
            inputData: {
                type: Object
            }
        },
        data() {
            return {
                whseidflag: true,
                rules: {},
            }
        },
        computed: {
            inputConfig() {
                return [
                    [
                        {
                            type: "select",
                            label: this.$t('config.reqreasonshortship'),
                            props: "reqreasonshortship",
                            options: this.getOptions('querycodeLkup/YESNO'),
                            disabled: this.whseidflag
                        },
                        {
                            type: "select",
                            label: this.$t('config.spsreturnlabel'),
                            props: "spsreturnlabel",
                            options: this.getOptions('querycodeLkup/YESNO'),
                            disabled: this.whseidflag
                        }
                    ]
                ]
            }
        },
        methods: {},
        mounted() {
            if (this.$store.state.wms.toUpperCase().includes('WMWHSE')) {
                this.whseidflag = false;
            }
        },
        components: {
            "v-detail": detail
        }
    }
</script>

<style scoped>

</style>
